package com.wswy.wyjk.ui

import com.raft.framework.arch.BaseViewModel
import com.wswy.wyjk.db.DataLoader
import com.wswy.wyjk.model.PracticeType

open class BasePracticeViewModel:BaseViewModel() {

    protected var dataLoader:DataLoader?=null

    var practiceType: PracticeType ?= null
    set(value) {
        if (value != practiceType && value != null){

            field = value

            dataLoader = DataLoader(value)
            onDataLoaderComplete()
        }

    }


    protected open fun onDataLoaderComplete(){

    }


}